package com.example.examy.entity;

import java.math.BigDecimal;

/**
 * @author 阳子龙
 */
public class Product {
    String name;//商品名称
    BigDecimal price;
    Double percentage = 1.0;
    Integer nums; //购买数量

    public Product(String name,Double price, Double percentage, Integer nums) {
        this.name = name;
        this.price = new BigDecimal(price);
        this.percentage = percentage;
        this.nums = nums;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public BigDecimal getPrice() {
        return price;
    }

    public void setPrice(BigDecimal price) {
        this.price = price;
    }

    public Double getPercentage() {
        return percentage;
    }

    public void setPercentage(Double percentage) {
        this.percentage = percentage;
    }

    public Integer getNums() {
        return nums;
    }

    public void setNums(Integer nums) {
        this.nums = nums;
    }
}
